Skip to content

Resolve simtools-tests directory when using integration tests config files in applications. - #2475

Merged
GernotMaier merged 10 commits into
mainfrom
sort-production-grid
Aug 31, 2026
Merged

Resolve simtools-tests directory when using integration tests config files in applications.#2475
GernotMaier merged 10 commits into
mainfrom
sort-production-grid

Conversation

@GernotMaier

@GernotMaier GernotMaier commented Aug 27, 2026

Copy link
Copy Markdown
Contributor

e.g. this works again:

python src/simtools/applications/production_generate_grid.py --config tests/integration_tests/config/production_generate_grid_horizontal_density.yml

and it resolve the path to corsika_limits: ${downloaded:corsika_limits.ecsv} corretly.

@GernotMaier GernotMaier self-assigned this Aug 27, 2026
@GernotMaier GernotMaier added the Copilot review AI-supported Copilot review label Aug 27, 2026
@GernotMaier GernotMaier changed the title Sort production grid tables Resolve simtools-tests directory when using integration tests config files in applications. Aug 31, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR improves how simtools resolves ${static:...}, ${generated:...}, and ${downloaded:...} resource macros when running applications against integration-test config files (i.e., using a versioned simtools-tests checkout via SIMTOOLS_TESTS_PATH + SIMTOOLS_TESTS_TAG). It also introduces deterministic sorting of serialized production job grids and updates dependency catalog defaults.

Changes:

  • Resolve test-resource macros against simtools-tests/<tag>/integration_tests when configured via environment variables (and adjust unit tests accordingly).
  • Sort production job-grid ECSV output deterministically during serialization and add a unit test for ordering.
  • Update dependency catalog defaults and add changelog fragments.

Reviewed changes

Copilot reviewed 10 out of 10 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
src/simtools/constants.py Adds environment-based selection of the active test-resources root via SIMTOOLS_TESTS_* variables.
src/simtools/io/io_handler.py Switches macro resolution and IOHandler default test-resources path to use the active/root-selection helper.
src/simtools/production_configuration/job_grid_io.py Sorts serialized job-grid tables by a set of configuration columns before writing.
tests/unit_tests/io/test_io_handler.py Adds coverage for resolving macros using versioned SIMTOOLS_TESTS_PATH + SIMTOOLS_TESTS_TAG.
tests/unit_tests/configuration/test_configurator.py Clears relevant env vars for stable resource-macro resolution behavior in the test.
tests/unit_tests/production_configuration/test_job_grid_io.py Adds a unit test asserting deterministic sorting in serialized job grids.
dependency_versions.yml Bumps model-database.default-tag to v0.17.1.
docs/changes/2473.feature.md Adds a changelog entry for job-grid sorting.
docs/changes/2483.model.md Adds a changelog entry for the model database default tag bump.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread src/simtools/constants.py Outdated
Comment thread src/simtools/production_configuration/job_grid_io.py Outdated
@ctao-sonarqube

Copy link
Copy Markdown

@GernotMaier
GernotMaier marked this pull request as ready for review August 31, 2026 08:42
@GernotMaier
GernotMaier merged commit 431a9d3 into main Aug 31, 2026
16 checks passed
@GernotMaier
GernotMaier deleted the sort-production-grid branch August 31, 2026 08:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Copilot review AI-supported Copilot review

Development

Successfully merging this pull request may close these issues.

2 participants